package AbstractTransactions

import (
	"Salary/Model"
	"fmt"
	"log"
)

type ChangeChangeMethodTransactions interface {
	GetMethod() Model.PaymentMethod
	GetSchedule() Model.PaymentSchedule
	Pay()
}


type ChangeMethodTransaction struct {
	ChangeEmployeeTransaction
	Model.PaymentMethod
	ChangeChangeMethodTransactions
}

func (cha *ChangeMethodTransaction)Changes(e Model.Employee){
	pm := cha.GetMethod()
	e.SetMethod(pm)
}

func (cha *ChangeMethodTransaction)Pay(pc Model.Paycheck ){
	err := fmt.Errorf("The method or operation is not implemented.")
	log.Println(err.Error())
}

